import { request } from '@pkg/request/src';

export enum Api {
    page = '/bcs/page',
    list = '/bcs/list',
    get = '/bcs/get',
    save = '/bcs/save',
    update = '/bcs/update',
    remove = '/bcs/remove',
}

/**
 * 保存或更新
 * @param params
 * @param isUpdate
 */
export const saveOrUpdate = (params, isUpdate) => {
    const url = isUpdate ? Api.update : Api.save;
    return request.post({ url: url, params });
};

/**
 * 查询详情
 * @param params
 */
export const getBusCarSeries = (params) => {
    return request.get({ url: Api.get, params });
};
